$OpenBSD: patch-gui-wx_configure_configure,v 1.3 2017/05/17 13:53:49 espie Exp $

Don't force -O2.

Index: gui-wx/configure/configure
--- gui-wx/configure/configure.orig
+++ gui-wx/configure/configure
@@ -3752,17 +3752,9 @@ $as_echo "$ac_cv_prog_cc_g" >&6; }
 if test "$ac_test_CFLAGS" = set; then
   CFLAGS=$ac_save_CFLAGS
 elif test $ac_cv_prog_cc_g = yes; then
-  if test "$GCC" = yes; then
-    CFLAGS="-g -O2"
-  else
-    CFLAGS="-g"
-  fi
+  CFLAGS="-g"
 else
-  if test "$GCC" = yes; then
-    CFLAGS="-O2"
-  else
-    CFLAGS=
-  fi
+  CFLAGS=
 fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
@@ -4679,17 +4671,9 @@ $as_echo "$ac_cv_prog_cxx_g" >&6; }
 if test "$ac_test_CXXFLAGS" = set; then
   CXXFLAGS=$ac_save_CXXFLAGS
 elif test $ac_cv_prog_cxx_g = yes; then
-  if test "$GXX" = yes; then
-    CXXFLAGS="-g -O2"
-  else
-    CXXFLAGS="-g"
-  fi
+  CXXFLAGS="-g"
 else
-  if test "$GXX" = yes; then
-    CXXFLAGS="-O2"
-  else
-    CXXFLAGS=
-  fi
+  CXXFLAGS=
 fi
 ac_ext=c
 ac_cpp='$CPP $CPPFLAGS'
@@ -6362,9 +6346,6 @@ $as_echo "$WX_PORT" >&6; }
                                 if test "$DEBUG" = "1"; then
             CXXFLAGS="$CXXFLAGS -g -O0"
             CFLAGS="$CFLAGS -g -O0"
-        else
-            CXXFLAGS="$CXXFLAGS -O2"
-            CFLAGS="$CFLAGS -O2"
         fi
 
  if test "x$WX_RESCOMP" != x; then
